<script>
	export default {
		globalData: {
			navH: '',
			statusBarHeight: '',
			isandroid: false,
		},
		onLoad(){},
		onLaunch() {
			this.getSystemInfo()
		},
		onShow: function() {
			console.log('App Show')
		},
		onHide: function() {
			console.log('App Hide')
		},
		methods: {
			// 获取设备信息
			getSystemInfo() {
				uni.getSystemInfo({
					success: res => {
						console.log('res', res)
						this.$options.globalData.navH = parseInt(Number(res.statusBarHeight) + (/android/i.test(res.platform) ? 44 :
							48)) // 自定义导航栏高度
						this.$options.globalData.statusBarHeight = parseInt(Number(res.statusBarHeight))
						this.$options.globalData.isandroid = /android/i.test(res.platform)
					}
				})
			},}
	};
</script>

<style lang="scss">
	@import "uview-ui/index.scss";

	* {
		box-sizing: border-box;
	}

	view {
		box-sizing: border-box;
	}

	.moveDown {
		animation: 0.5s moveDown forwards;
	}

	@keyframes moveDown {
		from {
			transform: translate3d(0, -100%, 0);
		}

		to {
			transform: translate3d(0, 0, 0);
		}
	}

	.moveUp {
		animation: 0.5s moveUp forwards;
	}

	@keyframes moveUp {
		from {
			transform: translate3d(0, 0, 0);
		}

		to {
			transform: translate3d(0, -100%, 0);
		}
	}


	.topMoveUp {
		animation: 0.5s topMoveUp forwards;
	}

	@keyframes topMoveUp {
		from {
			transform: translate3d(0, 100%, 0);
		}

		to {
			transform: translate3d(0, 0, 0);
		}
	}

	.topMoveDown {
		animation: 0.5s topMoveDown forwards;
	}

	@keyframes topMoveDown {
		from {
			transform: translate3d(0, 0, 0);
		}

		to {
			transform: translate3d(0, 100%, 0);
		}
	}
</style>
